Skip to content

Dr 7279 guides ai prompt button#7551

Open
ArthurGamby wants to merge 3 commits intomainfrom
dr-7279-guides-ai-prompt-button
Open

Dr 7279 guides ai prompt button#7551
ArthurGamby wants to merge 3 commits intomainfrom
dr-7279-guides-ai-prompt-button

Conversation

@ArthurGamby
Copy link
Contributor

@ArthurGamby ArthurGamby commented Feb 24, 2026

Summary by CodeRabbit

  • New Features

    • Added AI prompt banner to guide pages with one-click copy functionality for easy prompt sharing
    • Introduced Nuxt + Prisma framework prompt guide
  • Documentation

    • Added comprehensive guide for creating and integrating AI prompts into documentation pages
    • Enabled AI prompt integration for NextJS and Nuxt guides

@vercel
Copy link

vercel bot commented Feb 24, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
blog Ready Ready Preview, Comment Feb 24, 2026 1:13pm
docs Ready Ready Preview, Comment Feb 24, 2026 1:13pm

Request Review

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 24, 2026

Walkthrough

This PR introduces AI prompt integration functionality, enabling AI-assisted guide page setup. It includes documentation for creating prompts, a new Nuxt framework prompt, schema updates supporting aiPrompt metadata, a banner component to display prompts, and utilities to fetch and render prompts on guide pages.

Changes

Cohort / File(s) Summary
Documentation & Guides
apps/docs/PROMPT_GUIDE.md
New guide documenting the workflow for creating and integrating AI prompt banners into Prisma guide pages, including structure, required sections, and verification steps.
AI Prompt Content
apps/docs/content/docs/ai/prompts/nuxt.mdx
New comprehensive Nuxt + Prisma prompt file with setup workflow, environment configuration, API patterns, and AI model response templates emphasizing Prisma v7 patterns and security best practices.
Frontmatter Metadata
apps/docs/content/docs/guides/frameworks/nextjs.mdx, apps/docs/content/docs/guides/frameworks/nuxt.mdx
Added aiPrompt frontmatter field to link guide pages to their corresponding AI prompt content.
Schema Configuration
apps/docs/source.config.ts
Extended frontmatter schema in docs and docsV6 definitions to support optional aiPrompt field; includes formatting adjustments (quote style normalization).
Page Integration
apps/docs/src/app/(docs)/(default)/[[...slug]]/page.tsx
Integrated AI prompt fetching and rendering; conditionally loads and displays prompt content when aiPrompt metadata exists.
UI Component & Utilities
apps/docs/src/components/ai-prompt-banner.tsx, apps/docs/src/lib/get-prompt-content.ts
New client component AIPromptBanner for displaying a responsive banner with clipboard copy functionality; new utility function getPromptContent to extract and fetch prompt content from MDX files.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title directly describes the main change: adding an AI prompt button feature to guides, which is evident across multiple files implementing this functionality.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link
Contributor

🍈 Lychee Link Check Report

3664 links: ✅ 2740 OK | 🚫 0 errors | 🔀 258 redirects | 👻 664 excluded

✅ All links are working!


Full Statistics Table
Status Count
✅ Successful 2740
🔀 Redirected 258
👻 Excluded 664
🚫 Errors 0
⛔ Unsupported 2
⏳ Timeouts 0
❓ Unknown 0

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@apps/docs/PROMPT_GUIDE.md`:
- Around line 83-163: The Markdown fenced code block starting with the example
prompt template (the block beginning "# Bootstrap {Framework} app with Prisma
Postgres (Prisma v7)") is missing a language tag; update its opening fence from
``` to ```text to satisfy MD040 and improve syntax highlighting in
editors—ensure you only change the opening fence for that specific block in
PROMPT_GUIDE.md and keep the block contents unchanged.

In `@apps/docs/src/lib/get-prompt-content.ts`:
- Around line 11-13: The regex that extracts the fenced ```md block from the
`processed` string in `get-prompt-content` is currently brittle to CRLFs; update
the `processed.match(...)` call that computes `match` so the fence patterns
accept optional carriage returns (use `\r?\n` for both the opening and closing
fence line breaks) so it will match blocks with either `\n` or `\r\n` line
endings.

ℹ️ Review info

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between b2427d3 and d5a543e.

📒 Files selected for processing (8)
  • apps/docs/PROMPT_GUIDE.md
  • apps/docs/content/docs/ai/prompts/nuxt.mdx
  • apps/docs/content/docs/guides/frameworks/nextjs.mdx
  • apps/docs/content/docs/guides/frameworks/nuxt.mdx
  • apps/docs/source.config.ts
  • apps/docs/src/app/(docs)/(default)/[[...slug]]/page.tsx
  • apps/docs/src/components/ai-prompt-banner.tsx
  • apps/docs/src/lib/get-prompt-content.ts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant